﻿#region << 文件说明 >>

/*----------------------------------------------------------------
 * 命名空间：Vampirewal.Core.Models.FlowEngine
 * 唯一标识：7e28996c-c95f-4fd5-8984-90899a4465ca
 * 文件名：Flow
 *
 * 创建者：杨程
 * 电子邮箱：235160615@qq.com
 * 创建时间：2023/10/13 14:00:33
 * 版本：V1.0.0
 * 描述：
 *
 * ----------------------------------------------------------------
 * 修改人：
 * 时间：
 * 修改说明：
 *
 * 版本：V1.0.1
 *----------------------------------------------------------------*/

#endregion << 文件说明 >>



namespace Vampirewal.Core.Models.FlowEngine;

/// <summary>
/// 流程模型
/// </summary>
[SugarTable("Work_Flow", tableDescription: "流程表")]
public class Flow : BillBaseModel
{
    public Flow()
    {
        Units = new List<FlowUnit>();
        Links = new List<FlowLink>();
        Parameters = new List<FlowParam>();
    }

    /// <summary>
    /// 流程Code编号
    /// </summary>
    [SugarColumn(ColumnDescription = "流程Code编号")]
    public string FlowCode { get; set; }

    /// <summary>
    /// 描述
    /// </summary>
    [SugarColumn(ColumnDescription = "描述")]
    public string Description { get; set; }

    /// <summary>
    /// 状态
    /// </summary>
    [SugarColumn(ColumnDescription = "状态")]
    public int State { get; set; }

    /// <summary>
    /// 流程类型
    /// </summary>
    [SugarColumn(ColumnDescription = "流程类型")]
    public int FlowType { get; set; }

    /// <summary>
    /// 流程节点集合
    /// </summary>
    [SugarColumn(IsIgnore = true)]
    public List<FlowUnit> Units { get; set; }

    /// <summary>
    /// 流程节点连线集合
    /// </summary>
    [SugarColumn(IsIgnore = true)]
    public List<FlowLink> Links { get; set; }

    /// <summary>
    /// 流程节点参数集合
    /// </summary>
    [SugarColumn(IsIgnore = true)]
    public List<FlowParam> Parameters { get; set; }
}